Skip to content

Conversation

@bact
Copy link
Member

@bact bact commented Nov 2, 2024

  • Split cli tests to test_cli.py and testx_cli.py, test_cli will have only tests that do not require additional dependencies
  • Use safe_print (Add pythainlp.tools.safe_print to handle UnicodeEncodeError on console #969) so it plays nicely with UnicodeEncodeError on Windows console
  • Also set utf-8 in cli code and in GitHub workflow, so it can print Unicode characters
  • Errors related to Unicode in command line tests are now fixed

@coveralls
Copy link

coveralls commented Nov 2, 2024

Coverage Status

coverage: 39.162% (+6.0%) from 33.191%
when pulling 252e64e on bact:add-cli-tests
into 974b153 on PyThaiNLP:dev.

@bact bact added the tests Unit test, code coverage, test case label Nov 2, 2024
@sonarqubecloud
Copy link

sonarqubecloud bot commented Nov 2, 2024

@bact bact changed the title Split test_cli and testx_cli Make CLI able to handle Unicode characters output on Windows console Nov 2, 2024
@bact bact mentioned this pull request Nov 2, 2024
@bact bact merged commit cf6997f into PyThaiNLP:dev Nov 2, 2024
24 checks passed
@bact bact deleted the add-cli-tests branch November 2, 2024 09:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

tests Unit test, code coverage, test case

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants